1. Field of the Invention
The present invention relates to a method and apparatus for recording received digital data streams on a recording medium and creating and recording management information for the recorded digital data streams. The present invention also relates to a method and apparatus for reproducing data from a recording medium using the recorded management information.
2. Description of the Related Art
In conventional analog television broadcast, video signals are transmitted over the air or through cables after being AM or FM modulated. With the recent rapid advance of digital technologies such as digital image compression or digital modulation/demodulation, standardization for digital television broadcast is in rapid progress. Based upon the Moving Picture Experts Group (MPEG) format, satellite and cable broadcast industry also moves towards digital broadcast.
Digital broadcast offers several advantages that its analog counterpart cannot provide. For example, digital broadcast is capable of providing services with far more improved video/audio quality, transmitting several different programs within a fixed bandwidth, and offering enhanced compatibility with digital communication media or digital storage media.
In digital broadcast, a plurality of programs encoded based upon the MPEG format are multiplexed into a transport stream before transmitted. The transmitted transport stream is received by a set top box at the receiver and demultiplexed into a plurality of programs. If a program is chosen from among the demultiplexed programs, the chosen program is decoded by a decoder in the set top box and original audio and video signals are retrieved. The retrieved audio and video signals can be presented by an A/V output apparatus such as a TV.
It is also possible to store the received digital broadcast signals on a storage medium instead of directly outputting the received broadcast signals to A/V output devices. The stored digital broadcast signals can be edited and retrieved afterwards. For example, a digital data stream received by a set top box can be stored in a streamer such as a digital video disk (DVD) recorder through communication interfaces like an IEEE-1394 serial bus. Later, the stored digital data stream can be edited and transmitted back to the set top box so that the original digital audio and video data can be presented.
When a received digital data stream is recorded on a recording medium, management information regarding the digital data stream needs to be created and recorded on the recording medium. A conventional method for creating the management information will now be explained with reference to FIGS. 1 and 2.
If a user's request for recording an incoming data stream tuned by a tuning unit 110 has been received, a control unit 140 of a set top box 100 informs a control unit 250 of a streamer 200 that a recording mode is set and begins to transfer the received digital stream to the streamer 200 through an IEEE-1394 interface. The control unit 250 of the streamer 200 controls a stream recording unit 220 to record the received data stream on a recording medium 230. The transport stream packets (TS Pkt 1˜TS Pkt k) constituting the data stream are recorded on the recording medium 230 along with respective transport stream packet arrival times (TS APATs), wherein the transport stream packets with packet arrival times are organized in sectors on the recording medium 230.
When recording the digital stream, the control unit 250 of the streamer 200 groups the transport stream packets into stream object units (SOBU l˜SOBU q), with each stream object unit (SOBU) having a predetermined time length, for example, 0.5 s. The control unit 250 also creates a stream object unit size (SOBU_SZ) and a stream object unit presentation time (SOBU_TM) for each stream object unit (SOBU) and records the created information as management information for the associated stream object unit (SOBU). The stream object unit size (SOBU_SZ) of a stream object unit (SOBU) is expressed in terms of the number of sectors containing the stream object unit. If 20 stream object units (SOBUs) are created after 10 s elapses, the control unit 250 creates and records a stream object unit index number (SOBU_N) for the 20 stream object units.
The control unit 250 of the streamer 200 conducts the aforementioned task until the recording mode terminates, thereby creating a record (RCD) or program (PG). The digital stream recorded by a single recording operation is called a record (RCD) or program (PG). After the recording mode ends, the control unit 250 of the streamer 200 groups the created stream object units (SOBUs) into a stream object (SOB) and groups stream object unit sizes (SOBU_SZs) into a map. The map is recorded on the recording medium 230 as stream object information (SOBI).
Subsequently, the control unit 250 of the streamer 200 creates and records a presentation sequence information (Cell) with information linking it to the corresponding record (RCD) or program (PG).
If a user enters a search time (HH:MM:SS:FF) in order to search for a specific position on the recording medium 230, the control unit 250 of the streamer 200 detects a record (RCD) or program (PG) corresponding to the user's search time (HH:MM:SS:FF) with reference to the creation times (PG1_Create_TM, PG2_Create_TM, PG3_Create_TM) of records (RCD1˜RCD3) or programs (PG1˜PG3). Suppose the detected program is PG2 shown in FIG. 2. Then, the control unit 250 detects a Cell (Cell 2 shown in FIG. 2) corresponding to the user's search time (HH:MM:SS:FF) with reference to the presentation start time (C1_S_TM, C2_S_TM, . . . , Cn_S_TM) and presentation end time (C1_E_TM, C2_E_TM, . . ., Cn_E_TM) of each Cell contained in the detected program PG2.
Referring to the stream object information (SOBI) of the stream object SOB2 associated with the detected presentation sequence information Cell 2, the control unit 250 subtracts the stream object start time (SOB_S_TM) from the user's search time (HH:MM:SS:FF). The control unit 250 searches for a stream object unit (SOBU) based upon the size accumulated up to the stream object unit (SOBU) in which the presentation time accumulated up to the stream object unit (SOBU) is closest to the subtraction result without exceeding it.
Suppose that the stream object unit detected by the above-mentioned procedure is SOBUg shown in FIG. 2. As the next step, the control unit 250 detects the transport stream packet arrival time (TS APAT) of each transport stream packet from the first sector Sector 1 containing the detected stream object unit SOBUg and compares the packet arrival time with the user's search time (HH:MM:SS:FF). The control unit 250 starts to retrieve recorded data from the transport stream packet whose packet arrival time is after the user's search time and controls a stream reproducing unit 240 so that the retrieved data can be transferred to the set top box 100 through the IEEE-1394 interface 210.
As explained thus far, each stream object unit created by the conventional data stream recording method has a predetermined time length. Therefore, in the instance where the transport stream packet corresponding to the user's search time is the last transport stream packet recorded in the last sector (Sector n) of the associated stream object unit (SOBUg) as shown in FIG. 3, a significant search time is required to locate the target transport stream packet. This is because it takes time to obtain the packet arrival time of the last transport stream packet recorded in the last sector (Sector n) since the packet arrival time of the first transport stream packet recorded in the first sector (Sector 1) has been detected.
The required search time can be fairly reduced by decreasing the time length of each stream object unit. In this case, however, the number of stream object units (SOBUs) increases, which inevitably entails increased amount of overall navigation data as the management data regarding stream object units also increases.
In addition, since the time length of each stream object unit is fixed, the size of each stream object unit depends on the bit rate of the input data stream. For example, if an input digital data stream has a bit rate of 10 Mbps, the size of a stream object unit (SOBU) amounts to about 5 Mbit and thus the maximum search time required for locating a transport stream packet within a stream object unit (SOBU) is about 500 ms. In contrast, in the case of a data stream with a bit rate of 0.5 Mbps, a stream object unit (SOBU) has a size of 500 Kbit and the maximum search time required for locating a transport stream packet within a stream object unit (SOBU) amounts to about 50 ms.
Unless every recorded program or record has the same transfer rate, the size of a stream object unit varies depending on the transfer rate as shown in FIG. 4. The maximum search time, therefore, increases in proportion to the size of a stream object unit and transfer rate. Consequently, the search time is dependent upon the transfer rates of data streams in the conventional method, which may result in confusions and problems.